/**
 * @author xuyh0817
 * @email xuyh0817@foxmail.com
 * @date 2022-02-16 01:41
 * @version 2.0.0
 * @doc todo
 * @website todo
 * @remark  如果要分发源码，需在本文件顶部保留此文件头信息！！
 */
import {COMPONENT_TYPE} from '../../constants'

export default [
  {
    id: '1',
    type: COMPONENT_TYPE.SWITCH,
    formItem: {
      prop: 'value',
      rules: [],
      label: '默认值',
      extra: 'value(v-model)',
    },
    attrs: {
      checked: false
    }
  },
  {
    id: '2',
    type: COMPONENT_TYPE.SWITCH,
    formItem: {
      prop: 'disabled',
      rules: [],
      label: '禁用状态',
      extra: '是否禁用状态，默认为 false,整组失效',
    },
    attrs: {
      checked: false
    }
  },
  {
    id: '3',
    type: COMPONENT_TYPE.SWITCH,
    formItem: {
      prop: 'loading',
      rules: [],
      label: '加载中',
      extra: '加载中的开关',
    },
    attrs: {
      checked: false
    }
  },
  {
    id: '4',
    type: COMPONENT_TYPE.INPUT,
    formItem: {
      prop: 'checkedChildren',
      rules: [],
      label: '选中内容',
      extra: '选中时的内容',
    },
    attrs: {
      value: '',
      maxLength: 100,
      type: 'text',
      allowClear: true,
      placeholder: '请输入选中内容'
    }
  },
  {
    id: '5',
    type: COMPONENT_TYPE.INPUT,
    formItem: {
      prop: 'unCheckedChildren',
      rules: [],
      label: '非选中内容',
      extra: '非选中时的内容',
    },
    attrs: {
      value: '',
      maxLength: 100,
      type: 'text',
      allowClear: true,
      placeholder: '请输入非选中内容'
    }
  },
  {
    id: '6',
    type: COMPONENT_TYPE.RADIO_BUTTON,
    formItem: {
      prop: 'size',
      rules: [],
      label: '开关大小',
      extra: '开关大小，可选值：default small',
    },
    attrs: {
      buttonStyle: 'solid',
      value: 'default',
      children: [
        {
          value: 'default',
          label: 'default'
        },
        {
          value: 'small',
          label: 'small'
        }
      ]
    }
  }
]
